package com.jyx.iterator;

import com.jyx.iterator.arraylist.ArrayList;
import com.jyx.iterator.cat.Cat;
import com.jyx.iterator.collection.Collection;
import com.jyx.iterator.iterator.Iterator;
import com.jyx.iterator.linked.LinkedList;

/**
 * @author  作者: 蒋永星
 * @email       jiangyongxing@myzczk.com
 * @company		www.urbanspace.cn
 * @date 创建时间：2016年5月29日 下午5:00:01 
 * @version 1.0
 */
public class Test {

	public static void main(String[] args) {
		// ArrayList arrayList = new ArrayList();
		// for (int i = 0; i < 11; i++) {
		//  	arrayList.add(new Cat(i));
		// }
		// System.out.println(arrayList.size(0));
		
		/*LinkedList ll = new LinkedList();
		for (int i = 0; i < ll.size(); i++) {
			ll.add(new Cat(i));
		}
		System.out.println(ll.size());
		*/
		
		Collection c = new ArrayList();
		for (int i = 0; i < 11; i++) {
			c.add(new Cat(i));
		}
		System.out.println(c.size());
		
		Iterator it = c.iterator();
		while (it.hasNext()) {
			Object o = it.Next();
			System.out.println(o + "");
		}
		
		
	}
}
